{% extends 'layout.html' %}


{% block content %}

    <form class="form-horizontal col-lg-12" style="margin-top: 30px" method="post" novalidate>
        {% csrf_token %}

        {% for field in form_obj %}

            <div class="form-group {% if field.errors %}has-error{% endif %} ">

                <label for="{{ field.id_for_label }}" class="col-sm-2 control-label">{{ field.label }}</label>
                <div class="col-sm-7">
                    {{ field }}
                </div>
                <span class="help-block">{{ field.errors.0 }}</span>

            </div>
        {% endfor %}


        <div class="form-group">
            <div class="col-sm-offset-2 col-sm-10">
                <button type="submit" class="btn btn-default">保存</button>
            </div>
        </div>
    </form>





{% endblock %}